﻿

namespace Mulala.Cavan.TestAppService.ChargeModule
{
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using NUnit.Framework;
    using Spring.Context;
    using Spring.Context.Support;
    using Mulala.Cavan.Application.MainBoundedContext.ChargeModule;
    using Mulala.Cavan.Application.MainBoundedContext.MulalaModule;
    using Mulala.Cavan.Domain.Seedwork;
    using Mulala.Cavan.Domain.MainBoundedContext.CorporationModule;

    public class TestUserServiceAppService
    {
        private IApplicationContext context;
        private IUserServiceAppService UserServiceAppService { get; set; }

        [SetUp]
        public void SetUp()
        {
            context = ContextRegistry.GetContext();
        }

        [Test]
        public void TestAddUserServiceToCorporation()
        {
            this.UserServiceAppService = context.GetObject(MulalaAppServiceConst.USERSERVICEAPPSERVICE) as IUserServiceAppService;
            BoolGenericResult<Corporation> result = this.UserServiceAppService.AddUserServiceToCorporation(27, 2);

            Assert.AreEqual(true, result.IsSuccess);
        }
    }
}
